<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>domain</title>
</head>

<body style="border:1px solid black">
    a页面
    <iframe src="http://m.zbc.com:3000/b.html" frameborder="0" id="frame"></iframe>
    <script>
        document.domain = "zbc.com"
        var a = 'a页面数据'
        window.onload = function () {
            alert(frame.contentWindow.b)
        }
    </script>
</body>

</html>